import BaseStore from '@src/stores/base';

export default class ManagerStore extends BaseStore {
  list(params) {
    return this.apiGet('/managers', params);
  }

  add(params) {
    return this.apiPost('/manager', params);
  }

  get(params) {
    return this.apiGet('/manager/{manager_id}', { manager_id: params.id, ...params });
  }

  put(params) {
    return this.apiPut('/manager/{manager_id}', { manager_id: params.id, ...params });
  }

  del(params) {
    return this.apiDel('/manager/{manager_id}', { manager_id: params.id, ...params });
  }
}

export const Manager = new ManagerStore({ key: 'manager' });
